package com.mirror.repository;

import com.mirror.entity.building.Building;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface BuildingRepository extends JpaRepository<Building, String>, JpaSpecificationExecutor<Building> {


    Page<Building> findAllByIsdelOrderByBuildingName(Pageable pageable, boolean isdel);

    List<Building> findAllByIsdelOrderByBuildingName(boolean isdel);

}
